<?
$get_time_query = "SELECT * FROM team_time WHERE teamname='".$teamname."'";
$get_time = mysqli_query($connect, $get_time_query);
$time = mysqli_fetch_array($get_time);
mysqli_free_result($get_time);
?>

월
<select name="monday_start">
	<option value="0">시작시각</option>
<?
for ($count = 900; $count < 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['monday_start'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<select name="monday_end">
	<option value="0">종료시각</option>
<?
for ($count = 950; $count <= 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['monday_end'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
</select>
<br />

화
<select name="tuesday_start">
	<option value="0">시작시각</option>
<?
for ($count = 900; $count < 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['tuesday_start'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<select name="tuesday_end">
	<option value="0">종료시각</option>
<?
for ($count = 950; $count <= 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['tuesday_end'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<br />

수
<select name="wednesday_start">
	<option value="0">시작시각</option>
<?
for ($count = 900; $count < 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['wednesday_start'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<select name="wednesday_end">
	<option value="0">종료시각</option>
<?
for ($count = 950; $count <= 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['wednesday_end'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<br />

목
<select name="thursday_start">
	<option value="0">시작시각</option>
<?
for ($count = 900; $count < 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['thursday_start'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<select name="thursday_end">
	<option value="0">종료시각</option>
<?
for ($count = 950; $count <= 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['thursday_end'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<br />

금
<select name="friday_start">
	<option value="0">시작시각</option>
<?
for ($count = 900; $count < 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['friday_start'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<select name="friday_end">
	<option value="0">종료시각</option>
<?
for ($count = 950; $count <= 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['friday_end'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<br />

토
<select name="saturday_start">
	<option value="0">시작시각</option>
<?
for ($count = 900; $count < 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['saturday_start'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<select name="saturday_end">
	<option value="0">종료시각</option>
<?
for ($count = 950; $count <= 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['saturday_end'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<br />

일
<select name="sunday_start">
	<option value="0">시작시각</option>
<?
for ($count = 900; $count < 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['sunday_start'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<select name="sunday_end">
	<option value="0">종료시각</option>
<?
for ($count = 950; $count <= 2400; $count+=50) {
	echo "<option value=\"".$count."\"";
	if ($time['sunday_end'] == $count) echo " selected=\"selected\"";
	echo ">";

	$temp = $count/100;
	$hour = (int) $temp;
	if ($count%100 == 0) { $minute = '00'; }
	else {$minute = '30'; }

	echo $hour.":".$minute."</option>";
}
?>
</select>
<br />